package com.yueke.gemini.controller;

import com.yueke.gemini.common.ApiResult;
import com.yueke.gemini.entity.*;
import org.springframework.http.MediaType;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.ResponseBody;

import java.util.List;

/**
 * Created by admin on 2019/11/15.
 */
@RequestMapping(value = "/ref")
public interface IReferenceQueryController {


    /**
     * 获取模块
     *
     * @param query
     * @return
     */
    @RequestMapping(value = "/getKeyItems.do",method = RequestMethod.POST, produces = MediaType.APPLICATION_JSON_VALUE)
    @ResponseBody
    public ApiResult<List<KeyItem>> getKeyItems(@RequestBody RefQueryDTO query);


    /**
     *
     * @return
     */
    @RequestMapping(value = "/getModuleItem.do",method = RequestMethod.POST, produces = MediaType.APPLICATION_JSON_VALUE)
    @ResponseBody
    public ApiResult<List<ModuleItem>> getModuleItemList();


    /**
     *
     * @param query
     * @return
     */
    @RequestMapping(value = "/getRefModuleList.do",method = RequestMethod.POST, produces = MediaType.APPLICATION_JSON_VALUE)
    @ResponseBody
    public ApiResult<List<RefModule>> getRefModuleList(@RequestBody RefQueryDTO query);


    /**
     *
     * @param query
     * @return
     */
    @RequestMapping(value = "/getRefSubModuleList.do",method = RequestMethod.POST, produces = MediaType.APPLICATION_JSON_VALUE)
    @ResponseBody
    public ApiResult<List<SubRefModule>> getRefSubModuleList(@RequestBody RefQueryDTO query);

}
